//
//  LatestNotice.m
//  Contacts
//
//  Created by 李 雷川 on 14-8-17.
//  Copyright (c) 2014年 李 雷川. All rights reserved.
//

#import "LatestNotice.h"
#import "DateMethod.h"
@implementation LatestNotice
@synthesize ID,title,categoryID,time,iconUrl,objID;
+(LatestNotice *)analysisLatestNoticeWithDic:(NSDictionary *)dic{
    LatestNotice *notice = [[LatestNotice alloc]init];
    notice.ID = [dic[@"id"]integerValue];
    notice.title =dic[@"title"];
    notice.time = [NSDate dateWithTimeIntervalSince1970:[dic[@"timeLong"] longLongValue]/1000.0];
//    NSLog(@"timelong is:%lld",[dic[@"timeLong"]longLongValue] );
//    NSLog(@"notice.time is:%@", notice.time);
    
   // notice.time = [NSDate dateWithTimeIntervalSince1970:[dic[@"timeLong"] longValue]];
    notice.categoryID = [dic[@"category"] integerValue];
    notice.objID = [dic[@"objId"]integerValue];
    return notice;
}
@end
